package com.jboltai.common;
import java.util.ArrayList;
import java.util.List;

/**
 * 大模型使用场景枚举
 */
public enum LlmUseForEnum {
        CHAT("通用对话", "chat"),
        CODER( "代码专用","coder"),
        TOOLS( "工具调用","tools"),
        INTENTION( "意图识别","intention"),
        VISUAL("视觉理解","visual"),
        REASONER("深度思考","reasoner");
    private String value;
    private String text;
    LlmUseForEnum(String text,String value){
        this.text = text;
        this.value = value;
    }

    public String getValue() {
        return value;
    }

    public void setValue(String value) {
        this.value = value;
    }

    public String getText() {
        return text;
    }

    public void setText(String text) {
        this.text = text;
    }

    public static LlmUseForEnum getByValue(String value){
        for(LlmUseForEnum item : LlmUseForEnum.values()){
            if(item.getValue().equals(value)){
                return item;
            }
        }
        return null;
    }
    public String getTextByValue(String value){
        for(LlmUseForEnum item : LlmUseForEnum.values()){
            if(item.getValue().equals(value)){
                return item.getText();
            }
        }
        return null;
    }

    public static List<LlmUseForEnum> listAll(){
        List<LlmUseForEnum> list = new ArrayList<>();
        list.add(CHAT);
        list.add(CODER);
        list.add(TOOLS);
        list.add(INTENTION);
        list.add(VISUAL);
        list.add(REASONER);
        return list;
    }
}
